<!DOCTYPE html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="https://cdn.jsdelivr.net/npm/vue@2.6.12"></script>
</head>
<body>
   <script>
       var comElement=Vue.extend({
           template:'<div><h3>全局组件</h3><p>这是我们创建的全局组件</p></div>'
       })
       Vue.component('muComponent',comElement)
       var app=new Vue({
           el:'#app'
       });
   </script>
</body>

</html>
